IconTheme: Never fail a lookup or icon load
authorAlexander Larsson <alexl@redhat.com>
Wed, 5 Feb 2020 16:08:29 +0000 (17:08 +0100)
committerAlexander Larsson <alexl@redhat.com>
Thu, 6 Feb 2020 08:38:25 +0000 (09:38 +0100)
commitd69f7fd63ef736b26d45f563ca95f9fcffdffd47
treefb32c97917670cc9ccbf18bfa993b521f42dd221
parentadccd1391efa49faf82abe48bf52e5c9813844d2
IconTheme: Never fail a lookup or icon load

If icon lookup fails or if loading it fails later, just always
fall back to the built in image-missing icon. Nobody is handling
missing icons in a sane way anyway.

If you *truly* need to handle missing icons, you need to manually
use gtk_icon_theme_has_icon().

While changing the loading code I also fixed an issue where it
was always passing "png" to pixbuf, now it also handles "xpm" if
that is the filename suffix.
demos/gtk-demo/textview.c
gtk/gtkbuilder.c
gtk/gtkicontheme.c
gtk/gtkicontheme.h
gtk/gtkmountoperation.c
gtk/gtkwindow.c
tests/testclipboard2.c
tests/testdnd2.c
testsuite/gtk/icontheme.c